{extends file="main.tpl"}
{block name=head}
<script type="text/javascript">
$(document).ready(function()
{
  $('.checkAll').click(function () {
    if($(this).is(':checked'))
    {
      $('.checkboxAll').attr('checked','checked');
    }
    else
    {
    	$('.checkboxAll').removeAttr('checked');
    }
  });
});
function myFunction()
{
	if(confirm("You Want To Remove This Record")== true)
	{
		return true;
	}
	else
	{
		return false;
	}
}
</script>
{/block}
{block name=body}
<h2 align="center">PARTY LIST</h2>
<form method=POST name="BrandView" action="addressPrintPdf.php">
<table  border='2' align="center">
<tr>
	<th class="table1"><input type="checkbox" name="checkAll" id="checkAll" class="checkAll">
	                   <input type="submit" name="submitDateBtn" value="GO..." class="button"/>
	</th>
	<th class="table1">&nbsp;</th>
	<th class="table1">&nbsp;</th>
	<th class="table1">Party Name</th>
	<th class="table1">Mobile 1</th>
	<th class="table1">Mobile 2 </th>
	<th class="table1">Address 1</th>
	<th class="table1">Address 2</th>
	<th class="table1">Taluko</th>
	<th class="table1">Dist</th>
	<th class="table1">City</th>
	<th class="table1">Pin</th>
</tr>
{section name="sec" loop=$partyArray}
<tr>
	<td class="table2" align="center">
	  <a href="addressPrintPdf.php?partyId={$partyArray[sec].partyId}" class="link"><input type="checkbox" class="checkboxAll" name="checkedParty[]" value="{$partyArray[sec].partyId}">
	  </a>
	</td>
	<td class="table2" align="center">
	  <a href="party.php?partyId={$partyArray[sec].partyId}" class="link"><img src="./images/b_edit.png" height="20px" width="20px"></a>
	</td>
	<td class="table2" align="center">
	  <a href="addressDelete.php?partyId={$partyArray[sec].partyId}" onclick="return myFunction();" class="link"><img src="./images/deleteIcon.png" height="20px" width="20px"></a>
	</td>
	<td class="table2" align="left">{$partyArray[sec].partyName}</td>
	<td class="table2" align="left">{$partyArray[sec].mobile1}</td>
	<td class="table2" align="left">{$partyArray[sec].mobile2}</td>
	<td class="table2" align="left">{$partyArray[sec].add1}</td>
	<td class="table2" align="left">{$partyArray[sec].add2}</td>
	<td class="table2" align="left">{$partyArray[sec].taluko}</td>
	<td class="table2" align="left">{$partyArray[sec].dist}</td>
	<td class="table2" align="left">{$partyArray[sec].city}</td>
	<td class="table2" align="left">{$partyArray[sec].pin}</td>
</tr>
{/section}
</table>
</form>
{/block}